Hi,
I've no doubt the answer is here somewhere already but I cant find it !
I have a Photo Gallery pages(s) using custom content type using cck imagefield (with multiple values) and displaying imagecache presets. I have created a page view and worked out how to only display the first image from each node (group multiple). Where I'm stuck is getting the thumbnail to launch a slideshow with all images from the relevant gallery (node,page ??). I can link to the node with its horrible standard layout or I can link to a lightbox preset or imagecachepreset. When set as lightbox2-slideshow-thumb-original it only displays the first image (ie the thumb shown in the page view). If I turn off grouping(in views) the slideshow works but of course then I am seeing all of the thumbs instead of just the first one.
I've read many other posts and tweaked various Lightbox2 settings (automatic handlers,triggers etc) but no luck. On the views side of things I have tried displaying as fields or nodes - no go.
Is there a secret recipe ?
Any help greatly appreciated.
Shaun
Comments
Comment #1
stella commentedDuplicate of #232104: How to navigate image_fields
Comment #2
skroving commentedHi,
I did see this post but didnt pay too much attention to it as it applies to Drupal 5. I'm using 6.9 and being relatively new to Drupal am not to familiar with editing the system files.
I've re read it and would like to know if it still applies to 6.x and exactly where (what files) do I need to make these changes in ? I am not yet familiar with overriding functions etc, css tweaks are no prob.
Thanks for your help.
Shaun
PS: Here is the page I am trying to generate a slideshow from whilst only showing the first thumbnail of each node: http://122.252.12.44/~whitsund/photo_galleries
Comment #3
philingle commentedHi
I have looked through the existing issues with a smilar content (http://drupal.org/node/595586 and http://drupal.org/node/405794) and the one that this issue has been labled as a duplicate of http://drupal.org/node/232104 but none of them answer my question, which is the same as the original posters post title so I will post here to avoid creating another duplicate.
I have a custom content type, called accommodation, in that content type I have an image field, called field_accom_image which can store multiple values.
I have created two image cache presets 250-wide and 800-wide and when I look at the display fields option of my content type I can choose Lightbox2: 250-wide->800-wide or Lightbox2 slideshow: 250-wide->800wide (among many other options). Either of these produces the lightbox effect that I want.
However I get all 10 or 15 of my accommodation thumbnails on the page and I would only like to see one.
From what I have read it looks like I have a few options...
1) create a custom node template node-accommodation.tpl.php and build up my page bit by bit rather than using the $content variable and then customise the display of the accommodation image to show only one image. I have started down this road, using the details here http://drupal.org/node/274487 but I am struggling a bit and am out of my depth in php code
2) create a custom cck field template. I tried using the devel module to determine what to call this template file, it suggested content-field-field_accom_image-accommodation.tpl.php so I created this file, put it in my theme folder, and have tried putting some code in it to dispaly just one photo but it doesnt seem to be being used by my node. the devel module still says that the content-field.tpl.php template from the cck/theme folder is being used. So I am not sure how to get this to work either.
3) edit the lightbox formatters in lightbox2.formatter.inc to achieve this as per http://drupal.org/node/274487#comment-1218834 but I dont really want to get into modifying modules because I then break the upgrade path.
4) Create a view for my accommodation pages and use the views features to achieve the single thumbnail. I am not too familier with views so not sure how easy/hard this is to achieve
So my question is which is the best of these ways to achive this, where should I be putting my effort. Or is there another easier way to do this that I have missed.
Cheers and thanks for a great module
Comment #4
dwadson commentedTry the Compact view for multiple imagefield - it adds an additional formatter that displays only the first image of a multiple-value imagefield but the Lightbox allows you to view all the images.